home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 7 / Apprentice-Release7.iso / Source Code / Pascal / Snippets / PNL Libraries / Assembly / Completions.a < prev    next >
Text File  |  1994-08-04  |  938b  |  42 lines

  1. FSCompletion    PROC    EXPORT
  2.  
  3.     LINK    A6,#0                ; Link for the debugger.
  4.     MOVEM.L    A5,-(SP)            ; Preserve A5 register.
  5.     
  6.     MOVE.L    A0, -(SP)            ; Pass PB pointer as the parameter.
  7.     MOVE.L    -8(A0),A5            ; Set A5 to passed value (ourA5).
  8.     MOVE.L    -4(A0),A0            ; A0 = real completion routine address.
  9.     JSR        (A0)                ; Transfer control to ourCompletion.
  10.     
  11.     MOVEM.L    (SP)+,A5            ; Restore A5 register.
  12.     UNLK    A6                    ; Unlink.
  13.     RTS                            ; Return.
  14.     
  15.     STRING    ASIS                ; The debugger string.
  16.     DC.B    $8C,'FSCompletion',0
  17.     DC.W    $0000
  18.     STRING    PASCAL
  19.     
  20.     ENDP
  21.     
  22. TCPCompletion    PROC    EXPORT
  23.  
  24.     LINK    A6,#0                ; Link for the debugger.
  25.     
  26.     MOVE.L    8(A6), -(SP)        ; Pass PB pointer as the parameter.
  27.     MOVE.L    -4(A0),A0            ; A0 = real completion routine address.
  28.     JSR        (A0)                ; Transfer control to ourCompletion.
  29.     
  30.     UNLK    A6                    ; Unlink.
  31.     RTS                            ; Return.
  32.     
  33.     STRING    ASIS                ; The debugger string.
  34.     DC.B    $8D,'TCPCompletion'
  35.     DC.W    $0000
  36.     STRING    PASCAL
  37.     
  38.     ENDP
  39.     END
  40.  
  41. asm -wb "{active}"
  42.